/**
 * 验证手机号码 最宽松验证 1 开头即可
 *
 */

const validMobileLoose = (param) => {
  const reg = /^(?:(?:\+|00)86)?1\d{10}$/;
  if (reg.test(param)) {
    return true;
  } else {
    return false;
  }
};

/**
 * 验证手机号码 严格验证
 *
 */

const validMobileStrict = (param) => {
  const reg =
    /^(?:(?:\+|00)86)?1(?:(?:3[\d])|(?:4[5-79])|(?:5[0-35-9])|(?:6[5-7])|(?:7[0-8])|(?:8[\d])|(?:9[1589]))\d{8}$/;
  if (reg.test(param)) {
    return true;
  } else {
    return false;
  }
};
export { validMobileLoose, validMobileStrict };
